The present invention relates generally to handheld computers and smart cards. In particular the invention relates to low cost, low-power computerized cards with writeable memory.
A computerized smart card is typically a cuboid enclosure with dimensions on the order of 100 mmxc3x9740 mmxc3x975 mm of a resilient plastic material that includes a semiconductor chip capable of holding data and typically capable of supporting multiple user applications.
Physically, a smart card often resembles the commonplace credit card but having one or more semiconductor devices attached to a module embedded in the card, providing communication with the outside world typically, though not necessarily, via electrical contacts.
Though usage is commonplace, handheld computers and smart cards have been too expensive for ubiquitous use. A number of problems exist in reducing the cost of these to a minimum. Moreover, smart cards that implement any form of wireless (radio, optical, audio etc.) communication tend to be expensive and include some form of computerxe2x80x94typically a microcontroller. Low cost microcontrollers are well known in the art.
A bare minimum useful wireless handheld computer (or smart card) will comprise an enclosure, a electrical energy source, programmable microprocessor or microcontroller of some form, together with memory, operator controls, a wireless means for data input and a wireless means for data output. When a bare-bones handheld computer is designed for lowest possible cost, consistent with at least a minimal usefulness, it becomes apparent that the need for a microprocessor or microcontroller together with memory constitute a significant proportion of the total cost. Therefore it is desirable to use the cheapest possible microcontroller part (with on-board memory), consistent with energy constraints.
A minimally useful handheld computer will require three classes of memory:
1. A non-volatile, readable memory for storage of program codes and unchanging data. This memory may be, but need not be, a read-only memory (ROM).
2. A non-volatile, read/write memory for storage of data.
3. A read/write scratch pad memory with an effectively unlimited cycle life.
Various memory technologies are available, and indeed a battery backed complementary metal oxide semiconductor (CMOS) memory might meet the requirements of all three memory classes supra. However lower cost approaches are possible and such a xe2x80x9cbattery-CMOSxe2x80x9d device would need to be continuously energized.
Generally scratch pad memory is included with all microcontrollers, so is not a crucial design constraint in the present context.
Certain very low cost microcontrollers with on-board non-volatile memory at the present time provide a FLASH memory with a bulk erase feature. FLASH memories with bulk erase are well known in the art. For lowest possible cost it is desirable to use a single FLASH memory for both program codes and data. The cheapest microcontrollers with on-board FLASH memory are not primarily intended for use in such a mode. Rather the intention is that the FLASH memory shall be programmed using an external computer or programming machine of some kind and the memory shall be bulk erased with the same or a similar device. Such FLASH memory is intended to be used in a manner whereby it is erased all at once (in bulk) and then re-programmed in entirety.
Thus, a need exists for an extremely low cost smart card. Also, a need exists for a system, method and computer program product for implementing a computer system with persistent data storage implemented as a single FLASH memory.
Accordingly a system, method and computer program product is disclosed for implementing a computer system with persistent data storage using a single non-volatile FLASH memory.
A SwapCard (a trademark of SWAPCARD.COM Inc.) based upon an ATMEL (TM) AT89LV51 embedded microcontroller is disclosed. The AT89LV51 is a complementary metal-oxide semiconductor (CMOS) device, CMOS devices being common in the art. This microcontroller includes many features of the ""8051 microcontroller family"" members of which are well known in the art. This microcontroller includes 128 bytes of scratch pad memory and a single FLASH memory of(typically) 4 Kbytes. The first part of the FLASH memory is used to hold program codes and is written using an external programming computer in the factory when the SwapCard is manufactured. A second part of the FLASH memory is used to hold data and is read from and written to under the control of the program codes in the first part (i.e. the low address space) of the FLASH memory.
External to the microcontroller, programming circuitry is provided for programming an eight-bit byte into the second part of the FLASH memory. A significant constraint is that it is not possible for the microcontroller to fetch program instructions from the FLASH memory while a byte is being programmed. In fact, programming a byte of FLASH memory takes a much longer time that the typical instruction cycle time for the microcontroller. The microcontroller must be held in a reset state during programming, causing the ordinary program execution sequence to be disrupted.
Whenever programming of a byte to FLASH memory is completed the SwapCard (TM) circuitry external to the microcontroller releases the microcontroller RESET control wire and the firmware must recover its context. For cost reasons, no non-volatile memory is made available to store the context across data programming cycles. Thus, the firmware must recover its context from using a resource external to the SwapCard. One external source disclosed is a co-operating computer with which the SwapCard is in wireless communication.